package cn.py.boot_lua.pattern.strategy;

// 客户端代码
public class Client {
    public static void main(String[] args) {
        Context context = new Context();
        context.setStrategy(new ConcreteStrategyA());
        context.executeStrategy();  // 执行策略A

        context.setStrategy(new ConcreteStrategyB());
        context.executeStrategy();  // 执行策略B
    }
}